package reflect;

@AutoRunClass
public class Student {
    private String name = "张小三";
    private int age = 10;
    private String gender = "男";
    @AutoRun
    public void study(){
        System.out.println("学生:好好学习，天天向上!");
    }
    public void sayHello(){
        System.out.println("大家好，我是学生:"+name);
    }
    @AutoRun(5)
    public void play(){
        System.out.println("学生:一起做游戏~");
    }
    @AutoRun(7)
    public void test(){
        System.out.println("学生:一起做测试~");
    }

    @Override
    public String toString() {
        return "Student{" +
                "name='" + name + '\'' +
                ", age=" + age +
                ", gender='" + gender + '\'' +
                '}';
    }
}
